package softwaretest.repository;

import softwaretest.Domain.DeviceData;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface DeviceDataRepository extends JpaRepository<DeviceData, Long> {
    List<DeviceData> findTop10ByDevice_CategoryOrderByCreatedAtDesc(String category);
    DeviceData findFirstByDevice_CategoryOrderByCreatedAtDesc(String category);
}